package com.eduran.test.model;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import javax.inject.Inject;

@Component
public class Robot_032 {
    private int id = 0;
    private String speech = "hello";

    public void speak(){
        System.out.println(id + ": " + speech);
    }

    public int getId() {
        return id;
    }
    @Inject
    public void setId(@Value("1132") int id) {
        this.id = id;
    }

    public String getSpeech() {
        return speech;
    }
    @Autowired
    public void setSpeech(@Value("Selam ben geldim. ") String speech) {
        this.speech = speech;
    }
}
